/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package org.testis.utils;

/**
 *
 * @author selcuk
 */
//public enum SelectionType {
//    SELECT,
//    NOT_SELECT
//};

public class LabelRegexBuilder {

    public static final String SELECT_LABEL = "(?=.*\\blabel\\b)";
    public static final String NOT_SELECT_LABEL = "(?!.*\\blabel\\b)";

    public String getRegexForSingleLabel(String labelName, boolean select) {
        StringBuilder sb = new StringBuilder();
        String regex;
        if (select) {
            regex = SELECT_LABEL;
        } else {
            regex = NOT_SELECT_LABEL;
        }
        regex.replaceFirst("label", labelName);
        return sb.toString();
    }

}
